<?php
/**
 * Created by PhpStorm.
 * User: CaiJianling
 * Date: 2018/8/6
 * Time: 2:00
 */

session_start();
header('content-type:text/html;charset=utf-8');
///*当前页面代码顶部*/
////开启php缓存
//if (extension_loaded('zlib')) {
//    ob_end_clean();
//    ob_start('ob_gzhandler');
//} else {
//    ob_end_clean();
//    ob_start();
//}

if ($_SERVER['HTTP_HOST'] == 'localhost') {
    $php_shelf_host = '/posterPHP';

} else {
    $php_shelf_host = '';
}
if ($_SERVER['PHP_SELF'] == $php_shelf_host . '/admin/my.php') {
    if (!isset($_SESSION['uid']) || !isset($_SESSION['username'])) {
        ?>
        <script>
            alert("请登录");
            window.location.href = "./login.php";
        </script>
        <?php
        exit();
    }
}
?>


<link rel="icon" type="image/png" href="./assets/i/favicon.png">
<link rel="apple-touch-icon-precomposed" href="./assets/i/app-icon72x72@2x.png">
